Telegram Group & Telegram Channel
Всем привет, подскажите как 2 роутера использовать во Vue:

import router from './routes';
import adminRouter from './admin/routes';

createApp(App)
.use(router)
.use(adminRouter);


admin/router/index.js:
import { createRouter, createWebHistory } from 'vue-router';
import AdminLayout from "../layouts/AdminLayout.vue";
import Orders from '../pages/Orders.vue';

const routes = [
{ path: '/', component: AdminLayout, children: [
{ path: '/orders', name: 'AdminOrders', component: Orders, meta: {title: 'Заявки'} },
]
},
];

const adminRouter = createRouter({
history: createWebHistory('/admin'),
routes,
});

export default adminRouter;


routes/index.js:
import { createRouter, createWebHistory } from 'vue-router';
import AppLayout from "../layouts/AppLayout.vue";
import Main from '../pages/Main.vue';

const routes = [
{ path: '/', component: AppLayout, children: [
{ path: '/', name: 'Main', component: Main, meta: {title: 'Главная'} },
]
},
];

export default router;


Так вообще можно делать?? В консоли всякие ошибки



tg-me.com/vuejs_ru/1610778
Create:
Last Update:

Всем привет, подскажите как 2 роутера использовать во Vue:

import router from './routes';
import adminRouter from './admin/routes';

createApp(App)
.use(router)
.use(adminRouter);


admin/router/index.js:
import { createRouter, createWebHistory } from 'vue-router';
import AdminLayout from "../layouts/AdminLayout.vue";
import Orders from '../pages/Orders.vue';

const routes = [
{ path: '/', component: AdminLayout, children: [
{ path: '/orders', name: 'AdminOrders', component: Orders, meta: {title: 'Заявки'} },
]
},
];

const adminRouter = createRouter({
history: createWebHistory('/admin'),
routes,
});

export default adminRouter;


routes/index.js:
import { createRouter, createWebHistory } from 'vue-router';
import AppLayout from "../layouts/AppLayout.vue";
import Main from '../pages/Main.vue';

const routes = [
{ path: '/', component: AppLayout, children: [
{ path: '/', name: 'Main', component: Main, meta: {title: 'Главная'} },
]
},
];

export default router;


Так вообще можно делать?? В консоли всякие ошибки

BY Александр www in Vue.js — русскоговорящее сообщество


Warning: Undefined variable $i in /var/www/tg-me/post.php on line 283

Share with your friend now:
tg-me.com/vuejs_ru/1610778

View MORE
Open in Telegram


Vue js — русскоговорящее сообщество Telegram | DID YOU KNOW?

Date: |

The SSE was the first modern stock exchange to open in China, with trading commencing in 1990. It has now grown to become the largest stock exchange in Asia and the third-largest in the world by market capitalization, which stood at RMB 50.6 trillion (US$7.8 trillion) as of September 2021. Stocks (both A-shares and B-shares), bonds, funds, and derivatives are traded on the exchange. The SEE has two trading boards, the Main Board and the Science and Technology Innovation Board, the latter more commonly known as the STAR Market. The Main Board mainly hosts large, well-established Chinese companies and lists both A-shares and B-shares.

Telegram Be The Next Best SPAC

I have no inside knowledge of a potential stock listing of the popular anti-Whatsapp messaging app, Telegram. But I know this much, judging by most people I talk to, especially crypto investors, if Telegram ever went public, people would gobble it up. I know I would. I’m waiting for it. So is Sergei Sergienko, who claims he owns $800,000 of Telegram’s pre-initial coin offering (ICO) tokens. “If Telegram does a SPAC IPO, there would be demand for this issue. It would probably outstrip the interest we saw during the ICO. Why? Because as of right now Telegram looks like a liberal application that can accept anyone - right after WhatsApp and others have turn on the censorship,” he says.

Vue js — русскоговорящее сообщество from hk


Telegram Александр www in Vue.js — русскоговорящее сообщество
FROM USA